﻿package  {
	
	public class Block {
		private var tileType:int = 0;
		public var tile:mcTile = new mcTile;
		
		//Constructor
		public function Block(x:int, y:int, type:int) {			
			this.tileType = type;
			
			tile.width = 50;
			tile.height = 50;
			
			tile.x = x;
			tile.y = y;
			
			switch (type)
			{
				case 0 :
					tile.gotoAndStop(1);
					break;

				case 1 :
					tile.gotoAndStop(2);
					break;

				case 2 :
					tile.gotoAndStop(3);
					break;
			}
		}
		
		public function getTileType() : int {
			return this.tileType;
		}
	}	
}
